]> dgit.raspbian.org Git - gnome-shell.git/commit
util: Stop special-casing trySpawnCommandLine() parse errors
authorFlorian Müllner <fmuellner@gnome.org>
Sun, 12 Jan 2025 12:32:39 +0000 (13:32 +0100)
committerFlorian Müllner <fmuellner@gnome.org>
Sun, 12 Jan 2025 23:14:16 +0000 (00:14 +0100)
commitf0317cd9248616eebbf8da52162ffa6fef9bd339
tree27c04e5ebbb20dad1a91d84b4ee2db92e451c7de
parent8cee9eb562e66b9505726188e18db60830e415b1
util: Stop special-casing trySpawnCommandLine() parse errors

Unlike for plain JS Errors, the `message` property of GLib.Errors
is read-only, so the intent to replace it with a nicer message
triggers an Error itself.

We could create a new GLib.Error with the changed message instead,
but as it turns out, none of the parse errors contain the technical
prefix we want to strip out, so we can simply drop the special-casing
altogether.

This is also consistent with `spawnCommandLine()`, which never
had special treatment of parse errors.

Closes: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/8146
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3593>
(cherry picked from commit 67c5be9c5364cfe9ee2bd00b337582eb1527b939)
js/misc/util.js